Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add beforeEmailSent and beforeSmsSent trigger types #1621

Merged
merged 19 commits into from
Oct 21, 2024

Conversation

blidd-google
Copy link
Contributor

@blidd-google blidd-google commented Sep 19, 2024

Merges changes from the beforeEmailSent (#1492) and beforeSmsSent (#1589) PRs.

Copy link
Contributor

@egilmorez egilmorez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with tiny nits, thanks!

recaptchaActionOverride?: RecaptchaActionOptions;
}

/** The handler response type for beforeCreate blocking events */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's backtick this like the above event type.


/**
* Handles an event that is triggered before an email is sent to a user.
* @param opts - Object containing function options
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's add a period.


/**
* Handles an event that is triggered before an SMS is sent to a user.
* @param opts - Object containing function options
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing period.

export type EmailType = "EMAIL_SIGN_IN" | "PASSWORD_RESET";

/**
* The type of SMS message
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we include the comment below to the type comment above so it shows up in the reference docs?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With salient details about valid values in the text preferably, thanks!

Copy link
Contributor

@egilmorez egilmorez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG! Miniscule nit in doc string.

@@ -326,25 +334,50 @@ export interface Credential {
signInMethod: string;
}

/**
* Possible types of emails as described by the GCIP backend, which can be:
* - An sign-in email
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just "A sign-in email". (not "An")

@blidd-google blidd-google added this pull request to the merge queue Oct 21, 2024
Merged via the queue into master with commit 827ba0e Oct 21, 2024
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants